From: Andrew Cooper Date: Thu, 23 Jan 2014 12:55:42 +0000 (+0100) Subject: x86/irq: avoid use-after-free on error path in pirq_guest_bind() X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~5653 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=650fc2f76d0a156e23703683d0c18fa262ecea36;p=xen.git x86/irq: avoid use-after-free on error path in pirq_guest_bind() This is XSA-83. Coverity-ID: 1146952 Signed-off-by: Andrew Cooper Reviewed-by: Jan Beulich --- diff --git a/xen/arch/x86/irq.c b/xen/arch/x86/irq.c index a47d4f640b..db70077e4e 100644 --- a/xen/arch/x86/irq.c +++ b/xen/arch/x86/irq.c @@ -1590,8 +1590,7 @@ int pirq_guest_bind(struct vcpu *v, struct pirq *pirq, int will_share) printk(XENLOG_G_INFO "Cannot bind IRQ%d to dom%d. Out of memory.\n", pirq->pirq, v->domain->domain_id); - rc = -ENOMEM; - goto out; + return -ENOMEM; } action = newaction;